<div class="page-container">
	<div class="spinner-container" *ngIf="isPosting">
		<mdl-spinner [active]="true"></mdl-spinner>
	</div>
	<div class="edit-container">
		<mdl-layout-title>{{ IsEdit ? '编辑' : '添加' }}楼层</mdl-layout-title>
		<dynamic-form 
			#floorForm
			(getPlayLoad)="onLoadFormData($event)" 
			[ctrls]="formControls">
			
		</dynamic-form>
		
		<mdl-spinner *ngIf="isFormPosting" single-color active></mdl-spinner>
		<button mdl-ripple mdl-button mdl-button-type="raised" [disabled]="!floorForm.form.valid || isFormPosting" (click)="save(floorForm)" mdl-colored="primary">
			<i class="material-icons">done</i>保存
		</button>
		<a routerLink="/floor" mdl-ripple mdl-button mdl-button-type="raised" mdl-colored="accent">
		    <i class="material-icons">keyboard_arrow_left</i> 返回
	  	</a>
  	</div>
</div>